home *** CD-ROM | disk | FTP | other *** search
/ EnigmA Amiga Run 1995 October / EnigmA AMIGA RUN 01 (1995)(G.R. Edizioni)(IT)[!][issue 1995-10][Aminet 7].iso / Aminet / dev / gcc / ixemul_src.lha / ixemul-41.0 / man / cat2 / kill.0 < prev    next >
Text File  |  1992-08-10  |  3KB  |  133 lines

  1.  
  2. KILL(2)                    UNIX Programmer's Manual                    KILL(2)
  3.  
  4. NNAAMMEE
  5.      kkiillll - send signal to a process
  6.  
  7. SSYYNNOOPPSSIISS
  8.      ##iinncclluuddee <<ssyyss//ssiiggnnaall..hh>>
  9.  
  10.      _i_n_t
  11.      kkiillll(_p_i_d___t _p_i_d, _i_n_t _s_i_g)
  12.  
  13. DDEESSCCRRIIPPTTIIOONN
  14.      The kkiillll() function sends the signal given by _s_i_g to _p_i_d, a process or a
  15.      group of processes.  _S_i_g may be one of the signals specified in sigac­
  16.      tion(2) or it may be 0, in which case error checking is performed but no
  17.      signal is actually sent.  This can be used to check the validity of _p_i_d.
  18.  
  19.      For a process to have permission to send a signal to a process designated
  20.      by _p_i_d, the real or effective user ID of the receving process must match
  21.      that of the sending process or the user must have appropriate privileges
  22.      (such as given by a set­user­ID program or the user is the super­user).
  23.      A single exception is the signal SIGCONT, which may always be sent to any
  24.      descendant of the current process.
  25.  
  26.      If _p_i_d is greater than zero:
  27.              _S_i_g is sent to the process whose ID is equal to _p_i_d_.
  28.  
  29.      If _p_i_d is zero:
  30.              _S_i_g is sent to all processes whose group ID is equal to the pro­
  31.              cess group ID of the sender, and for which the process has per­
  32.              mission; this is a variant of killpg(2).
  33.  
  34.      If _p_i_d is ­1:
  35.              If the user has super user privileges, the signal is sent to all
  36.              processes excluding system processes. If the user is not the su­
  37.              per user, the signal is sent to all processes with the same uid
  38.              as the user except the process sending the signal.  No error is
  39.              returned if any process could be signaled.
  40.  
  41.      For compatibility with System V, if the process number is negative but
  42.      not ­1, the signal is sent to all processes whose process group ID is
  43.      equal to the absolute value of the process number.  This is a variant of
  44.      killpg(2).
  45.  
  46. RREETTUURRNN VVAALLUUEESS
  47.      Upon successful completion, a value of 0 is returned.  Otherwise, a value
  48.      of ­1 is returned and _e_r_r_n_o is set to indicate the error.
  49.  
  50. EERRRROORRSS
  51.      KKiillll() will fail and no signal will be sent if:
  52.  
  53.      [EINVAL]  _S_i_g is not a valid signal number.
  54.  
  55.      [ESRCH]   No process can be found corresponding to that specified by _p_i_d.
  56.  
  57.      [ESRCH]   The process id was given as 0 but the sending process does not
  58.                have a process group.
  59.  
  60.      [EPERM]   The sending process is not the super­user and its effective us­
  61.                er id does not match the effective user­id of the receiving
  62.                process.  When signaling a process group, this error is re­
  63.                turned if any members of the group could not be signaled.
  64.  
  65. SSEEEE AALLSSOO
  66.      getpid(2),  getpgrp(2),  killpg(2),  sigaction(2)
  67.  
  68. SSTTAANNDDAARRDDSS
  69.      The kkiillll() function is expected to conform to IEEE Std 1003.1­1988
  70.      (``POSIX'').
  71.  
  72. 4th Berkeley Distribution       March 10, 1991                               2
  73.  
  74.  
  75.  
  76.  
  77.  
  78.  
  79.  
  80.  
  81.  
  82.  
  83.  
  84.  
  85.  
  86.  
  87.  
  88.  
  89.  
  90.  
  91.  
  92.  
  93.  
  94.  
  95.  
  96.  
  97.  
  98.  
  99.  
  100.  
  101.  
  102.  
  103.  
  104.  
  105.  
  106.  
  107.  
  108.  
  109.  
  110.  
  111.  
  112.  
  113.  
  114.  
  115.  
  116.  
  117.  
  118.  
  119.  
  120.  
  121.  
  122.  
  123.  
  124.  
  125.  
  126.  
  127.  
  128.  
  129.  
  130.  
  131.  
  132.  
  133.